package com.tmanager.web.servlets;

import java.io.IOException;
import java.util.Date;

import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import com.google.inject.Inject;
import com.tmanager.persistence.dao.UserDAO;
import com.tmanager.persistence.entity.User;
import com.tmanager.web.services.AddedActivityService;
import com.tmanager.web.services.UserActivityService;

public class UserActivityServlet extends InjectedHttpServlet {
	@Inject
	private UserDAO userDAO;
	
	@Inject
	private UserActivityService userActivityService;
	
	@Override
	protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException,
			IOException {
		request.setCharacterEncoding("UTF-8");
		response.setCharacterEncoding("UTF-8");
		response.setContentType("text/html");
		//String data = request.getParameter(REQUEST_ACTIVITY_JSON);
		response.getWriter().append(userActivityService.getActivity(null, 0, new Date().getTime()));
	}
}
